1. Technical Field
The present invention relates generally to an improved data processing system and in particular to a method and apparatus for processing data. Still more particularly, the present invention relates to a method, apparatus, and computer instructions for providing hardware assistance for program reliability and correctness.
2. Description of Related Art
In writing code, programmers use different languages to generate software systems. These software systems may range from email server and handling systems to mission critical systems, such as the software systems used by various stock exchanges and banks. In performing these tasks, a programmer may generate code which is not correct. Programs have semantic properties and syntactic properties. Semantic properties relate to behavior, while syntactic properties relate to well-formedness. The semantic properties of the program may be checked for correctness statically during compile time and dynamically during runtime. Errors in program correctness may result in failures during execution or in incorrect results being generated by the system software. Additionally, when programs are compiled from a source code to a target code, the compiler used may not always provide a correct transformation of the code.
Currently, formal verification, verifying compilers, thorough testing of code, and runtime software checks are used to verify or insure program correctness. In practice, large software systems will still exhibit unexpected behavior even through the use of these techniques. Compilers often have bugs and even when correct can only add runtime software checks that are thought of by the compiler. Further, testings are often performed on debug versions of software systems being developed, rather than on the exact version of the code used by customers. This situation requires that changes made to the debug version also are made to the version that is to be used by customers. If the different versions are not synchronized, then correct operation in a debug version does not necessarily result in the same operation in the customer version.
Unanticipated behavior in system software is annoying. In the case of mission critical systems, this situation may be disastrous if systems fail or generate incorrect results because program correctness did not occur. Therefore, it would be advantageous to have an improved method, apparatus, and computer instructions for increasing the reliability of software by providing additional checks of program correctness at runtime.